MobileControlDo
Execute specific behaviors of native mobile controls created using mobileControlCreate.Syntax: mobileControlDo , , ...action specific parameters... Examples: mobileControlDo "myPlayerControl", "play" mobileControlDo tScrollerControlID, "flashScrollIndicators" mobileControlDo tBrowserControlName, "execute", "alert('javascript browser test')" mobileControlDo tFieldControlName, "focus" // set the focus for a multi-line text field mobileControlDo "myMultiLineTextInput", "focus" Use the mobileControlDo command to execute behaviors specific to a particular native mobile control created using mobileControlCreate. An action may require or have a number of optional extra parameters which are defined in the values section below. Parameters: *idOrName: The id or name of the control. *action (enum): The action to perform. Browser Specific Actions Scroller SpecificActions (iOS Only) Player Specific Actions Text Input Specific ActionsMulti-line Text Input Specific Actions Multi-line Text Input SpecificActions (iOS Only) * - "maxWidth (optional)": If maxWidth and maxHeight are specified, the snapshot is scaled to fit within a rectangle of that size but preserving the frame's aspect ratio. - "maxHeight (optional)": If maxWidth and maxHeight are specified, the snapshot is scaled to fit within a rectangle of that size but preserving the frame's aspect ratio. * - "advance": Move forward through the history (wraps the goForward method of UIWebView).- "retreat": Move backward through the history (wraps the goBack method of UIWebView).- "reload": Reload the current page (wraps the reload method of UIWebView). - "stop": Stop loading the current page (wraps the stopLoading method of UIWebView).- "load baseUrl, htmlText": Loads as page consisting of the given htmlText with the given baseUrl (wraps theloadHtmlString method of UIWebView). Takes the following additional parameters:- "baseUrl": - "htmlText": - "execute, script": Evaluates the given JavaScript script in the context of the current page (wraps the stringByEvaluationJavaScriptFromString method of UIWebView). Takes the following additional parameter:- "script": - "flashScrollIndicators": Makes the scroll indicators flash momentarily. - "play": Start playing the content of the player.- "pause": Pause the content at the current position.- "stop": Stop playing the content of the player.- "prepareToPlay" (iOS Only): Make the content ready to play, but don't actually commence playback.- "begin seeking forward" (iOS Only): Start seeking forward through the content of the player.- "begin seeking backward" (iOS Only): Start seeking backward through the content of the player.- "end seeking" (iOS Only): Stop seeking through the content of the player. - "snapshot | snapshot exactly, time, [ maxWidth, maxHeight ]" (iOS Only): Take a snapshot of the movie at time milliseconds from the beginning. If the 'exactly' form is specified the frame produced is as close as possible to time, otherwise the nearest keyframe is used. The snapshot is made available as a new image object cloned from the templateImage, with data in the format as specified by the global paintCompression property. Takes the following additional parameters: - "time": The milliseconds from the beginning.- "focus": Focus on the control. On iOS this will also display the keyboard. - "scrollRangeToVisible rangeStart, rangeLength": Ensures the given text range is visible in the view by changing the scroll of the field. - "rangeStart": The start index of the text that is to be made visible. - "rangeLength": The length of the text that is to be made visible. * Description:Use the mobileControlDo command to execute behaviors specific to aparticular native mobile control created using mobileControlCreate. Anaction may require or have a number of optional extra parameters whichare defined in the values section below. See also: mobileControlSet (command),mobileControlGet (function),mobileControlTarget (function),mobileControls (function),